#!/bin/bash

MyLogSetDir=$DEVICE/CompileConfig/logo
MyChiphdSyscfgSetDir=$DEVICE/CompileConfig/chiphdsyscfg
MyBoardConfigSetDir=$DEVICE/CompileConfig/boardconfig
MyInitSun7iSetDir=$DEVICE/CompileConfig/initsun7i

if [ "$OUT" ]; then
rm -rf $OUT/system/ $OUT/root/
fi

if	[ "$1" = "help" ]
then
	echo "./selct_board_super.sh A7008_AIMEI"
	echo "./selct_board_super.sh A7008_SANYI"
	echo "./selct_board_super.sh A7008_XST"	
	echo "./selct_board_super.sh Q8"
	echo "./selct_board_super.sh Q11"		
	echo "./selct_board_super.sh cj7102-3"				
	return 0
elif [ "$1" = "A7008_AIMEI" ]
then
cp $MyLogSetDir/initlogo_7008_aimei.rle 	$DEVICE/initlogo.rle  && echo -e "cp initlogo OK"
cp $MyChiphdSyscfgSetDir/ChipBuildCfg_7008aimei.mk 	$DEVICE/ChipBuildCfg.mk && echo -e "cp ChipBuildCfg OK"
cp $MyBoardConfigSetDir/BoardConfig_common.mk 	$DEVICE/BoardConfig.mk && echo -e "cp BoardConfig OK"
cp $MyInitSun7iSetDir/init.sun7i_anpei.rc 	$DEVICE/init.sun7i.rc && echo -e "cp init.sun7i OK"

#-------------A6502-AIMEI-----------------
elif [ "$1" = "A6502_AIMEI" ]
then
echo -e "A6502-AIMEI"
cp $MyLogSetDir/initlogo_6502_aimei.rle 	$DEVICE/initlogo.rle  && echo -e "cp initlogo OK --- zfl"
cp $MyChiphdSyscfgSetDir/ChipBuildCfg_6502aimei.mk 	$DEVICE/ChipBuildCfg.mk && echo -e "cp ChipBuildCfg OK --- zfl"
cp $MyBoardConfigSetDir/BoardConfig_6502_aimei.mk 	$DEVICE/BoardConfig.mk && echo -e "cp BoardConfig OK --- zfl"
cp $MyInitSun7iSetDir/init.sun7i_6502_anpei.rc 	$DEVICE/init.sun7i.rc && echo -e "cp init.sun7i OK --- zfl"

elif [ "$1" = "A7008_SANYI" ]
then
cp $MyLogSetDir/initlogo_7008_sanyi.rle 	$DEVICE/initlogo.rle  && echo -e "cp initlogo OK"
cp $MyChiphdSyscfgSetDir/ChipBuildCfg_7008sanyi.mk 	$DEVICE/ChipBuildCfg.mk && echo -e "cp ChipBuildCfg OK"
cp $MyBoardConfigSetDir/BoardConfig_common.mk 	$DEVICE/BoardConfig.mk && echo -e "cp BoardConfig OK"
cp $MyInitSun7iSetDir/init.sun7i_sanyi.rc 	$DEVICE/init.sun7i.rc && echo -e "cp init.sun7i OK"

elif [ "$1" = "A7008_HONGXIANG" ]
then
cp $MyLogSetDir/initlogo_1024600.rle 	$DEVICE/initlogo.rle  && echo -e "cp initlogo OK"
cp $MyChiphdSyscfgSetDir/ChipBuildCfg_7008hx.mk 	$DEVICE/ChipBuildCfg.mk && echo -e "cp ChipBuildCfg OK"
cp $MyBoardConfigSetDir/BoardConfig_common.mk 	$DEVICE/BoardConfig.mk && echo -e "cp BoardConfig OK"
cp $MyInitSun7iSetDir/init.sun7i_hongxiang.rc 	$DEVICE/init.sun7i.rc && echo -e "cp init.sun7i OK"

elif [ "$1" = "A7008_XST" ]
then
cp $MyLogSetDir/initlogo_7008_xst.rle 	$DEVICE/initlogo.rle  && echo -e "cp initlogo OK"
cp $MyChiphdSyscfgSetDir/ChipBuildCfg_7008sanyi.mk 	$DEVICE/ChipBuildCfg.mk && echo -e "cp ChipBuildCfg OK"
cp $MyBoardConfigSetDir/BoardConfig_common.mk 	$DEVICE/BoardConfig.mk && echo -e "cp BoardConfig OK"
cp $MyInitSun7iSetDir/init.sun7i_xst.rc 	$DEVICE/init.sun7i.rc && echo -e "cp init.sun7i OK"

elif [ "$1" = "Q8" ]
then
cp $MyLogSetDir/initlogo_800480.rle 	$DEVICE/initlogo.rle  && echo -e "cp initlogo OK"
cp $MyChiphdSyscfgSetDir/ChipHDSysCfg_800480.mk 	$DEVICE/ChipBuildCfg.mk && echo -e "cp ChipBuildCfg OK"
cp $MyBoardConfigSetDir/BoardConfig_common.mk 	$DEVICE/BoardConfig.mk && echo -e "cp BoardConfig OK"
cp $MyInitSun7iSetDir/init.sun7i_common.rc 	$DEVICE/init.sun7i.rc && echo -e "cp init.sun7i OK"


elif [ "$1" = "Q8-WCB" ]
then
cp $MyLogSetDir/initlogo_800480.rle 	$DEVICE/initlogo.rle  && echo -e "cp initlogo OK"
cp $MyChiphdSyscfgSetDir/ChipHDSysCfg_800480.mk 	$DEVICE/ChipBuildCfg.mk && echo -e "cp ChipBuildCfg OK"
cp $MyBoardConfigSetDir/BoardConfig_common.mk 	$DEVICE/BoardConfig.mk && echo -e "cp BoardConfig OK"
cp $MyInitSun7iSetDir/init.sun7i_common_wcb.rc 	$DEVICE/init.sun7i.rc && echo -e "cp init.sun7i OK"

elif [ "$1" = "Q8-1024" ]
then
cp $MyLogSetDir/initlogo_1024600.rle 	$DEVICE/initlogo.rle  && echo -e "cp initlogo OK"
cp $MyChiphdSyscfgSetDir/ChipBuildCfg_Q8_1024600.mk 	$DEVICE/ChipBuildCfg.mk && echo -e "cp ChipBuildCfg OK"
cp $MyBoardConfigSetDir/BoardConfig_common.mk 	$DEVICE/BoardConfig.mk && echo -e "cp BoardConfig OK"
cp $MyInitSun7iSetDir/init.sun7i_common.rc 	$DEVICE/init.sun7i.rc && echo -e "cp init.sun7i OK"

elif [ "$1" = "Q11" ]
then
cp $MyLogSetDir/initlogo_800480.rle 	$DEVICE/initlogo.rle  && echo -e "cp initlogo OK"
cp $MyChiphdSyscfgSetDir/ChipBuildCfg_Q8_800480.mk 	$DEVICE/ChipBuildCfg.mk && echo -e "cp ChipBuildCfg OK"
cp $MyBoardConfigSetDir/BoardConfig_q11.mk 	$DEVICE/BoardConfig.mk && echo -e "cp BoardConfig OK"
cp $MyInitSun7iSetDir/init.sun7i_q11.rc 	$DEVICE/init.sun7i.rc && echo -e "cp init.sun7i OK"

elif [ "$1" = "Q11-V17" ]
then
cp $MyLogSetDir/initlogo_800480_v17.rle 	$DEVICE/initlogo.rle  && echo -e "cp initlogo OK"
cp $MyChiphdSyscfgSetDir/ChipBuildCfg_Q11_V17_800480.mk 	$DEVICE/ChipBuildCfg.mk && echo -e "cp ChipBuildCfg OK"
cp $MyBoardConfigSetDir/BoardConfig_q11.mk 	$DEVICE/BoardConfig.mk && echo -e "cp BoardConfig OK"
cp $MyInitSun7iSetDir/init.sun7i_q11.rc 	$DEVICE/init.sun7i.rc && echo -e "cp init.sun7i OK"

elif [ "$1" = "Q11-V17S" ]
then
cp $MyLogSetDir/initlogo_1024600.rle 	$DEVICE/initlogo.rle  && echo -e "cp initlogo OK"
cp $MyChiphdSyscfgSetDir/ChipBuildCfg_Q8_1024600.mk 	$DEVICE/ChipBuildCfg.mk && echo -e "cp ChipBuildCfg OK"
cp $MyBoardConfigSetDir/BoardConfig_q11.mk 	$DEVICE/BoardConfig.mk && echo -e "cp BoardConfig OK"
cp $MyInitSun7iSetDir/init.sun7i_q11_v17s.rc 	$DEVICE/init.sun7i.rc && echo -e "cp init.sun7i OK"

elif [ "$1" = "cj7102-3" ]
then
cp $MyLogSetDir/initlogo_800480.rle 	$DEVICE/initlogo.rle  && echo -e "cp initlogo OK"
cp $MyChiphdSyscfgSetDir/ChipBuildCfg_changjia7102-3.mk 	$DEVICE/ChipBuildCfg.mk && echo -e "cp ChipBuildCfg OK"
cp $MyBoardConfigSetDir/BoardConfig_changjia_m11.mk 	$DEVICE/BoardConfig.mk && echo -e "cp BoardConfig OK"
cp $MyInitSun7iSetDir/init.sun7i_changjia.rc 	$DEVICE/init.sun7i.rc && echo -e "cp init.sun7i OK"
cp $DEVICE/res/media_profiles_cj7102.xml 	$DEVICE/media_profiles.xml && echo -e "cp media_profiles OK"

elif [ "$1" = "cj8101" ]
then
cp $MyLogSetDir/initlogo_1024768.rle 	$DEVICE/initlogo.rle  && echo -e "cp initlogo OK"
cp $MyChiphdSyscfgSetDir/ChipHDSysCfg_1024600_8101.mk 	$DEVICE/ChipBuildCfg.mk && echo -e "cp ChipBuildCfg OK"
cp $MyBoardConfigSetDir/BoardConfig_changjia_m11.mk 	$DEVICE/BoardConfig.mk && echo -e "cp BoardConfig OK"
cp $MyInitSun7iSetDir/init.sun7i_changjia.rc 	$DEVICE/init.sun7i.rc && echo -e "cp init.sun7i OK"
#cp $DEVICE/res/media_profiles_cj7102.xml 	$DEVICE/media_profiles.xml && echo -e "cp media_profiles OK"


elif [ "$1" = "N713" ]
then
cp $MyLogSetDir/initlogo_1024600_n713.rle 	$DEVICE/initlogo.rle  && echo -e "cp initlogo OK"
cp $MyChiphdSyscfgSetDir/ChipBuildCfg_1024600_N713.mk 	$DEVICE/ChipBuildCfg.mk && echo -e "cp ChipBuildCfg OK"
cp $MyBoardConfigSetDir/BoardConfig_q11.mk 	$DEVICE/BoardConfig.mk && echo -e "cp BoardConfig OK"
cp $MyInitSun7iSetDir/init.sun7i_N713.rc 	$DEVICE/init.sun7i.rc && echo -e "cp init.sun7i OK"

elif [ "$1" = "M11" ]
then
cp $MyLogSetDir/initlogo_1024768.rle 	$DEVICE/initlogo.rle  && echo -e "cp initlogo OK"
cp $MyChiphdSyscfgSetDir/ChipHDSysCfg_1024600.mk 	$DEVICE/ChipBuildCfg.mk && echo -e "cp ChipBuildCfg OK"
cp $MyBoardConfigSetDir/BoardConfig_changjia_m11.mk 	$DEVICE/BoardConfig.mk && echo -e "cp BoardConfig OK"
cp $MyInitSun7iSetDir/init.sun7i_m11.rc 	$DEVICE/init.sun7i.rc && echo -e "cp init.sun7i OK"

elif [ "$1" = "N914" ]
then
cp $MyLogSetDir/initlogo_n914.rle  	$DEVICE/initlogo.rle  && echo -e "cp initlogo OK"
cp $MyChiphdSyscfgSetDir/ChipHDSysCfg_n914.mk 	$DEVICE/ChipHDSysCfg.mk && echo -e "cp ChipHDSysCfg OK"
cp $MyBoardConfigSetDir/BoardConfig_n914.mk 	$DEVICE/BoardConfig.mk && echo -e "cp BoardConfig OK"
cp $MyInitSun7iSetDir/init.sun7i_n914.rc 	$DEVICE/init.sun7i.rc && echo -e "cp init.sun7i OK"
elif [ -z "$1" ]
then
	echo "no input, ignal..."
fi

	


